import Request from "../../../utils/request.js";
export default class {
  //提交推介
  static referralsCreate(params) {
    return Request({
      url: "app/referrals/create",
      type: "POST",
      data: params,
      headers: {
        "Content-type": "application/json"
      },
    })
  }
  //是否开通钱包
  static walletCenter(params) {
    var accountId = wx.getStorageSync('userId');
    return Request({
      url: "app/wallet/center/getWalletUser",
      type: "POST",
      data: {...params,accountId},
      headers: {
        "Content-type": "application/json"
      },
    })
  }
  //查询楼盘详情
  static queryEstateDetail(params) {
    return Request({
      url: `app/estate/houseDetail/${params}`,
      type: "GET"
    })
  }

  // 二级推荐默认给一级经纪人
  static counselorAction(params) {
    return Request({
      url: `app/counselor/queryDefaultCounselor?productId=${params}`,
      type: "GET"
    })
  }



  //二维码埋点，计算
  static visitNum(params) {
    return Request({
      //todo:
      url: `app/qrcode/visit`,
      type: "post",
      data: params,
    })
  }

  //客户详情
  static customDetailGet(params) {
    return Request({
      url: "app/customer/detail",
      type: "POST",
      data: params,
      headers: {
        "Content-type": "application/json"
      },
    })
  }
} 